﻿using System.Collections.Generic;
using CoreLibrary.Repo;
using Entities.DataBase.Obj;
using Entities.DataBase.Persistent;

namespace Entities.DataBase {

    public interface IOrderRepository : IRepository<Order> {
        
        Order Get(int orderId);
        List<Order> ListByCustomerId(string customer);

        List<OrderInfo> ListAll();
        List<OrderInfo> ListMany(int offset, int limit);
        List<OrderInfo> SearchOrders(SearchOrderReq request);

        void Create(Order order, List<OrderRecord> records);
        void Remove(int orderId);
        void RemoveByGuid(string guid);
        void Update(int orderId, OrderUpdator updator);
        void UpdateStatus(int orderId, int status);

    }
}